/* eslint-disable */
import request from "@/request";

/** deleteProductImage POST /api/api/product/image/delete */
export async function deleteProductImageUsingPost(
  body: API.ProductImage,
  options?: { [key: string]: any }
) {
  return request<API.BaseResponseBoolean_>("/api/api/product/image/delete", {
    method: "POST",
    headers: {
      "Content-Type": "application/json",
    },
    data: body,
    ...(options || {}),
  });
}

/** deleteByProductId POST /api/api/product/image/delete/product */
export async function deleteByProductIdUsingPost(
  body: API.ProductImage,
  options?: { [key: string]: any }
) {
  return request<API.BaseResponseBoolean_>(
    "/api/api/product/image/delete/product",
    {
      method: "POST",
      headers: {
        "Content-Type": "application/json",
      },
      data: body,
      ...(options || {}),
    }
  );
}

/** getProductImages POST /api/api/product/image/list */
export async function getProductImagesUsingPost(
  body: API.ProductImage,
  options?: { [key: string]: any }
) {
  return request<API.BaseResponseListProductImage_>(
    "/api/api/product/image/list",
    {
      method: "POST",
      headers: {
        "Content-Type": "application/json",
      },
      data: body,
      ...(options || {}),
    }
  );
}

/** saveProductImages POST /api/api/product/image/save */
export async function saveProductImagesUsingPost(
  body: API.ProductImageBatchRequest,
  options?: { [key: string]: any }
) {
  return request<API.BaseResponseBoolean_>("/api/api/product/image/save", {
    method: "POST",
    headers: {
      "Content-Type": "application/json",
    },
    data: body,
    ...(options || {}),
  });
}
